import { Component, OnInit, Output, EventEmitter } from '@angular/core';

@Component({
  selector: 'app-quick-task',
  templateUrl: './quick-task.component.html',
  styles: []
})
export class QuickTaskComponent implements OnInit {
  @Output()
  sendBtnClicked = new EventEmitter<void>();
  desc: string;
  constructor() { }
  ngOnInit() { }
  onSubmit({ value, valid }, e: Event) {
    e.preventDefault();
    console.log(value, valid);
  }
  onClick(e) {
    if (this.desc == null || this.desc.length == 0 || this.desc.trim()) {
      this.sendBtnClicked.emit();
    }
  }
}
